GBML manual / Getting started

Getting started

What Gbabel is made of, what each tab is for, and the path from opening the editor to a game running in an emulator.

What Gbabel is

Gbabel is a program for making games for the Game Boy Advance (GBA), Nintendo's handheld from

  1. You build a game in this editor, and Gbabel turns it into a ROM: a single .gba file,

the same kind of file a real GBA cartridge holds. You play a ROM in an emulator, a program on your computer that pretends to be a GBA. Gbabel starts one for you when a build finishes, once File → Setup knows which one to use.

Three parts work together, and it helps to know which is which:

Your game itself is none of those. It is a project: an ordinary folder on your computer that holds everything you made. The tool opens a project and never contains one.

The path from here to a running game

  1. Start Gbabel with Launch GBAB.bat, not by opening the page directly. The launcher starts a small server on your computer, and building a game, editing sprites and installing templates all need it. Use Chrome, Edge or another Chromium-based browser, because Gbabel reads and writes your project folder through a feature only those browsers have.
  2. Open or start a project. Every time it starts, Gbabel asks you to open a project folder or make a new one. A new one starts from a template: Blank, or a small finished game to learn from - Top-down, Platformer, Shooter, Snake, Sokoban, Brick breaker and others. There are also examples, each a tiny project about one technique: doors, dialogue, a pause menu, saving.
  3. Set up the build once. Click File → Setup and tell Gbabel where devkitPro, the Game Boy Advance module and Python are on your computer, and which emulator to use. You need this only to build a ROM. Writing and reading code works without it.
  4. Make something. Place things in a room, and give them behavior in the Code tab. The tabs below say where each job happens.
  5. Press ▶ Build & Play, or Ctrl+B. Gbabel saves the project, checks it, builds the ROM and opens it in your emulator. If something is wrong, it tells you which line.

A first game in ten minutes walks through all five once, with real code, and is the best next page.

What the tabs are for

The tab bar runs along the top of the editor. Each tab is one kind of job.

TabWhat you do there
✏ Room EditorBuild the rooms your game takes place in: add rooms, paint tiles, and drop objects into them. See Rooms, tiles and tile animation.
🗺 MapA minimap of how your rooms connect to each other.
🧩 CodeWrite what things do. Objects, scripts and events live here, as text, as blocks, or both side by side. See The Code tab and Blocks and code.
PathsDraw a route once and have any number of things follow it. See The Paths tab.
🎬 CutscenesScript a conversation or a camera move that plays at a set moment.
✨ ParticlesDesign effects like sparks, smoke and flames, with a live preview that behaves the way the GBA will.
🎵 MusicBring in songs, convert an mp3 or wav into a format the GBA can play, and edit tracker music.
🎨 PaintDraw sprites and tiles in a built-in pixel editor. It needs the launcher's server.
📖 ManualThis manual: every function, variable, constant and event, with its contents always beside the page.
❓ HelpShort, task-shaped help for the editor itself. Press F1 from anywhere.

Two toolbar buttons are worth knowing before anything else. 💾 Save writes everything to your project folder (Ctrl+S). ✓ Validate checks your rooms against the GBA's real limits, without building anything.

What is in a project folder

A project is plain files, so you can see what Gbabel saved:

In the folderWhat it holds
game.gbabel.jsonthe project's own settings: its name, its rooms, its objects, its input actions
objects/one folder per object, with a file for each event you wrote
scripts/code that belongs to no single object and can be called from any of them
rooms/one file per room
paths/the routes you drew
effects/the particle effects you designed
assets/your sprites, tiles, sounds and music

You can move the folder, copy it or keep it in version control. What goes into the ROM explains which of these files a build uses.

The GBA has hard limits

A real GBA can draw at most 128 sprites at once, so the editor shows gauges for these limits as you work. They are not Gbabel's choices. They are the console's, and going over one on real hardware does not produce a friendly message. Budgets explains each one, and the ❓ Help tab's GBA limits cheat sheet lists them in one place.

Where to go next

See also: A first game in ten minutesWhen each event runsThe Code tabBlocks and codeRooms, tiles and tile animationBuilding and reading its problemsWhat GBML is